package framework;


import com.microtf.inscription.framework.service.BlogService;
import com.microtf.inscription.framework.service.StorageService;
import lombok.Setter;
import org.springframework.beans.factory.annotation.Autowired;

import javax.annotation.PostConstruct;
import javax.annotation.PreDestroy;

@Setter
public class BeanRegister {

    BlogService blogService;
    String name;
    StorageService storageService;

    @Autowired
    public void setBlogService(BlogService blogService) {
        this.blogService = blogService;
    }

    public StorageService getStorageService() {
        return storageService;
    }
    @Autowired
    public void setStorageService(StorageService storageService) {
        this.storageService = storageService;
    }

    public BeanRegister() {
    }
    @PostConstruct
    public void PostCon(){
        System.out.println("PostConstruct");
    }
    public void sayHello(){
        System.out.println(name+"Hello");
    }
    @PreDestroy
    public void preDestroy(){
        System.out.println("preDestroy");
    }
}
